package com.huilian.cloud.module.system.dal.mysql.frontendbackendpermission;

import java.util.*;

import com.huilian.cloud.framework.common.pojo.PageResult;
import com.huilian.cloud.framework.mybatis.core.query.LambdaQueryWrapperX;
import com.huilian.cloud.framework.mybatis.core.mapper.BaseMapperX;
import com.huilian.cloud.module.system.dal.dataobject.frontendbackendpermission.FrontendBackendPermissionDO;
import org.apache.ibatis.annotations.Mapper;
import com.huilian.cloud.module.system.controller.admin.frontendbackendpermission.vo.*;

/**
 * 前后端关联标识 Mapper
 *
 * @author 芋道源码
 */
@Mapper
public interface FrontendBackendPermissionMapper extends BaseMapperX<FrontendBackendPermissionDO> {

    default PageResult<FrontendBackendPermissionDO> selectPage(FrontendBackendPermissionPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<FrontendBackendPermissionDO>()
                .eqIfPresent(FrontendBackendPermissionDO::getApi, reqVO.getApi())
                .eqIfPresent(FrontendBackendPermissionDO::getApiMethod, reqVO.getApiMethod())
                );
    }

}